package cc.yugu.yhdw.webserver.persistence.basic;

import cc.yugu.yhdw.common.domain.basic.AgentInOutMoney;
import cc.yugu.yhdw.common.persistence.MasterMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
/**
 * 代理商收入映射
 *
 * @Date:Created in 2018/6/27 18:09
 * @Author:
 * @Modified By: zjn 2018/6/27 18:09
 */
public interface AgentInOutMoneyMapper extends MasterMapper {
    /**
    * 根据运营商id查询，返回对应的行数
    *
    * @Param: [search]
    * @Return: int
    * @Author By: zjn 2018/6/27  18:09
    */
    public int findPageCount(AgentInOutMoney search);
    /**
    * 分页， 根据运营商id查询表bas_agent_in_out_money中对应的数据，并按照降序排列显示
    *
    * @Param: [search]
    * @Return: java.util.List<cc.yugu.yhdw.common.domain.basic.AgentInOutMoney>
    * @Author By: zjn 2018/6/27  20:03
    */
    public List<AgentInOutMoney> findPageResult(AgentInOutMoney search);


//    public int findPageCounts(AgentInOutMoney search);
//    public List<AgentInOutMoney> findPageResults(AgentInOutMoney search);

    /**
    * 新增：查询(2个参数的话，不是对象的话要入参Param)
    *
    * @Param:
    * @Return:
    * @Author By: zjn 2018/8/17  11:50
    */
    public List<AgentInOutMoney> find(@Param("agentId") Integer agentId, @Param("bizType")Integer bizType);

    /**
    * 根据运营商id删除表中数据
    *
    * @Param: [agentId]
    * @Return: int
    * @Author By: zjn 2018/6/27  20:08
    */
    public int deleteByAgent(int agentId);
    /**
    * 插入数据到表中
    *
    * @Param: [record]
    * @Return: int
    * @Author By: zjn 2018/6/27  20:09
    */
    public int insert(AgentInOutMoney record);
}
